home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Almathera Ten Pack 2: CDPD 1
/
Almathera Ten on Ten - Disc 2: CDPD 1.iso
/
pd
/
101-125
/
108
/
alist
/
alist.doc
< prev
next >
Wrap
Text File
|
1995-03-13
|
6KB
|
125 lines
AList command for the CLI ... use as a replacement for List and Dir.
Version 0.06 (dated 02-Sep-1987 at 21:13:42).
Based (loosely) on LD4 by Dave Haynie for directory access, "Dir"
for the idea of sorting the entries and "List" for output content.
Usage: AList [>prt:] [dirname] [opt pcvl23 | -c -l42 -p -v]\n
CasE is NOT significant ... mix & match, if you like.
Except for ">prt:" first, order is NOT significant.
? = display command format.
where: dirname = the Amiga drive (df0:, dh1:, etc.), the name of
a disk (WorkBench:, etc.) or a full path name, as
WorkBench:devs/keymaps.
c = color display desired (orange directories).
l = number of lines to display before pausing, value
may be 3 (although DUMB) through 999.
p = re-directing to printer ... you tell AList that you
used ">prt:" in the command line, and AList indents
its output so there is room to punch holes in the
list for storing in a binder. Please note that a
form-feed will initiate the listing!
v = verbose ... displays the current version data, and
displays the number of files/directories during the
input/sort phase.
opt = "Dir" format of specifying options.
- = Compiler format of specifying options.
Use whichever format turns you on, but not both!
anything unexpected = DISPLAY COMMAND FORMAT.
If you are re-directing to the printer (>prt:), you can now use "v",
as the display of the number of files/directories found will be eliminated.
The use of the "c" option has no value in re-direction unless you have a
color printer ... it won't hurt, but it sure won't generate color!
If no argument is supplied, the current directory will be displayed.
F_i_l_e___N_a_m_e_____________ _Keys_ __Size_ Blocks MM-DDD-YYYY HH:MM:SS
WorkBench_1.2 (BOLD) 880 Root 0 27-Jul-1987 22:19:40
TrashCan.info (normal) 889 654 2 27-Jul-1987 22:19:38
c (italicized) 882 Dir 0 27-Jul-1987 22:10:13
AList (indented) 884 17828 36 29-Aug-1987 13:55:12
etc. I took great pains to ensure that everything would
line up properly under the headings, to maximize readability. File names
belonging to a sub-directory are indented to catch the eye.
I am including source code for this, my first Amiga programming effort,
my first program in "C", so that some expert out there may be able to tell
me why some of the flaky things happen every now and then ... like 1,248
bytes not being returned to "Free Memory" EVERY time "AList" is run. I am
using AList every session myself, but with 2.5M the 1248 is not a problem,
but for someone on a 256K Amiga (or even 512K) you need to get it all back!
I am releasing the Lattice 3.10 "C" source code to Fred Fish, local
bulletin boards and maybe even Commodore-Amiga. It may be used freely by
anyone brave enough to do so, modified, extended or --->TrashCan. If you
do use the command, especially if you find (and fix) any bugs, I would
appreciate a letter telling me what the problem is(/was) and any fixes you
have made.
Bugs fixed:
Version 0.06:
Disk icons will now disappear when you eject the disk after the
use of "AList" on it ... I've cleared ALL the Lock's (I hope).
No more "GURU" meditations when using "AList" on the current
directory. (I now only clear Lock's I have set.) Sometimes the
problem manifested itself in the NEXT CLI command hanging/GURUing.
Version 0.03:
Long disk volume names are no longer a problem ... try AList on
"Copy of WorkBench 1.2" on this version if you downloaded v0.00.
Aesthetics ... you don't HAVE to see "AList compiled on ... ".
Statistics ... you CAN get the number of files/directories.
Bugs(?) to be fixed in a later version:
Approximately 1,248 characters are NOT returned to Free Memory
after EACH run of "AList". When I find out what is not being
"Free"d, I will Free it (providing its mine to Free!).
Support for control-c (^c) to break early ... why you'd want
to break I don't know, but since you can now ^c "Dir", I may as
well try to duplicate as much of "Dir" as possible in "AList",
Features to be added in a later version:
Option "p" will result in "AList" doing the output to "prt:",
so you don't have to use ">prt:" in the command line.
Option "d" will be added for compatibility with "Dir" (for any
of you brave enough to replace Dir with AList, but habitually use
opt d from time-to-time).
I may also add Opt "i" if I get any requests for it, but
"I DON'T DO DELETES!".
CAVEAT!!!
Since I don't support ^c in AList, don't use the #@%*& thing,
as you're going to get a "GURU", sure as my name's Ed Kivi!
Hope you find this creation amusing/useful/instructive/(?), so Enjoy!
Please address any comments, bug reports, postage stamps, etc. to:
A. Edwin Kivi
** SUGAR
P. O. Box 5970
Lacey, WA 98503
"C"'ya (signed) Ed Kivi
** SUGAR = Sunset User Group / Amiga Resources